Skip to content

refactor(Locallynameless): abbrev multiApp = List.foldl app - #710

Open
lengyijun wants to merge 4 commits into
leanprover:mainfrom
awesome-lambda-calculus:multiapp
Open

refactor(Locallynameless): abbrev multiApp = List.foldl app#710
lengyijun wants to merge 4 commits into
leanprover:mainfrom
awesome-lambda-calculus:multiapp

Conversation

@lengyijun

@lengyijun lengyijun commented Jul 12, 2026

Copy link
Copy Markdown
Contributor

Replace the recursive multiApp definition with List.foldl app
Remove the now-unnecessary multiApp_tail lemma and adapt proofs to List.foldl_concat
grind [multiApp_tail] => grind
Make semanticMap_saturated use explicit grind only: performance consideration
New theorems : multiapp_openRec multiapp_fv step_multiApp_l_union steps_multiApp_l_union
Rename listFullBeta_cons_r/l to listFullBeta_concat_r/l to reflect their general concatenation
Add specialized cons lemmas for reducing the head term or the tail list.

Fix #784

@lengyijun

lengyijun commented Jul 12, 2026

Copy link
Copy Markdown
Contributor Author

No option to allow maintainers to edit pull requests @chenson2018

@chenson2018

Copy link
Copy Markdown
Collaborator

!radar

@leanprover-radar

leanprover-radar commented Jul 12, 2026

Copy link
Copy Markdown

Benchmark results for a9b4873 against 056cf93 are in. There are significant results. @chenson2018

  • 🟥 build//instructions: +61.1G (+3.04%)

Large changes (1🟥)

1 hidden

@lengyijun

Copy link
Copy Markdown
Contributor Author

!radar

@leanprover-radar

leanprover-radar commented Jul 14, 2026

Copy link
Copy Markdown

Benchmark results for 4128bf4 against e5ed905 are in. No significant results found. @lengyijun

  • 🟥 build//instructions: +61.5G (+2.98%)

Medium changes (1🟥)

  • 1 hidden

@chenson2018 chenson2018 self-assigned this Jul 25, 2026
Comment thread Cslib/Languages/LambdaCalculus/LocallyNameless/Stlc/StrongNorm.lean Outdated
Comment thread Cslib/Languages/LambdaCalculus/LocallyNameless/Untyped/ListFullBeta.lean Outdated
@lengyijun

lengyijun commented Aug 9, 2026

Copy link
Copy Markdown
Contributor Author

When formalizing "2 vars are not enough", I have proved dozens of theorems related to this file

https://github.com/lengyijun/Fokker_challenge/blob/2varsareenough_new/FokkerChallenge/EnhancedCslib/FlipApp.lean

@lengyijun
lengyijun force-pushed the multiapp branch 2 times, most recently from 01b9a56 to 2e72322 Compare August 9, 2026 14:09
@lengyijun
lengyijun marked this pull request as draft August 10, 2026 00:40
@lengyijun
lengyijun force-pushed the multiapp branch 5 times, most recently from 2fea2c7 to 7affea2 Compare September 2, 2026 05:19
Replace the recursive multiApp definition with List.foldl app
Remove the now-unnecessary multiApp_tail lemma and adapt proofs to List.foldl_concat
Make semanticMap_saturated use explicit grind only lemmas for the new multiApp representation
New theorems : multiapp_openRec and multiapp_fv
@lengyijun lengyijun changed the title refactor(Locallynameless): Multiapp => List.foldl refactor(Locallynameless): multiApp => List.foldl app Sep 2, 2026
@lengyijun lengyijun changed the title refactor(Locallynameless): multiApp => List.foldl app refactor(Locallynameless): abbrev multiApp = List.foldl app Sep 2, 2026
@lengyijun
lengyijun force-pushed the multiapp branch 2 times, most recently from e182ced to c5a5623 Compare September 2, 2026 05:28
@lengyijun
lengyijun marked this pull request as ready for review September 2, 2026 05:30
Rename `listFullBeta_cons_r/l` to `listFullBeta_concat_r/l` to reflect their general concatenation behavior.
Add specialized `cons` lemmas for reducing the head term or the tail list.
Add `step_multiApp_l_union` to lift a single `(Xi R1 ⊔ Xi R2)` reduction through a multi-application.
Add `steps_multiApp_l_union` for the corresponding reflexive-transitive closure.
Use the new single-step lemma to simplify the proof of the multi-step result.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

listFullBeta_cons_r should rename to listFullBeta_concat_r

3 participants